package view;

import java.awt.Point;

public class BoundBox
{
	private int x;
	private int y;
	
	private int width;
	private int height;
	
	
	public boolean contains(Point p)
	{
		if (p.x >= x && p.x < x+width)
			if (p.y >= y && p.y < y+height)
				return true;
		
		return false;
	}

	
	
	@Override
	public String toString()
	{
		String result = x + ", " + y + ", " + width + ", " + height;
		
		return result;
	}
	
	
	/*
	 * ******************************************
	 * 				Getters & Setters
	 * ******************************************
	 * 
	 */
	
	public int getX()
	{
		return x;
	}

	public void setX(int x)
	{
		this.x = x;
	}

	public int getY()
	{
		return y;
	}

	public void setY(int y)
	{
		this.y = y;
	}

	public int getWidth()
	{
		return width;
	}

	public void setWidth(int width)
	{
		this.width = width;
	}

	public int getHeight()
	{
		return height;
	}

	public void setHeight(int height)
	{
		this.height = height;
	}
	
	
}
